package com.serviceprovider.business.module.admin.transaction.model;

public class CSVToFlatTableMapping {
    private String description;
    private int    id;
    private String name;

    @Override
    public boolean equals(Object obj) {
        if ((obj == null) ||!(obj instanceof CSVToFlatTableMapping)) {
            return false;
        }

        CSVToFlatTableMapping b = (CSVToFlatTableMapping) obj;

        if (id != b.id) {
            return false;
        }

        boolean eq = ((name == null) && (b.name == null)) || ((name != null) && name.equals(b.name));

        if (!eq) {
            return false;
        }

        eq = ((description == null) && (b.description == null))
             || ((description != null) && description.equals(b.description));

        if (!eq) {
            return false;
        }

        return true;
    }

    @Override
    public int hashCode() {
        int prime  = 31;
        int result = 1;

        result = prime * result + id;
        result = prime * result + ((name == null)
                                   ? 0
                                   : name.hashCode());
        result = prime * result + ((description == null)
                                   ? 0
                                   : description.hashCode());

        return result;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }
}



